﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;

namespace ActiveStory.DataManager.LinkMapData
{
    public class LinkMapPageElement
    {
        public ActiveStoryPageMetadata PageMetadata { get; private set; }
        public ActiveStoryPage Page { get; private set; }
        public List<UIElement> UiElements { get; private set; }
        public Rect BoundingBox { get; set; }

        /// <summary>
        /// Default constructor, defaults the position to (0,0)
        /// </summary>
        /// <param name="pageMetadata"></param>
        public LinkMapPageElement(ActiveStoryPageMetadata pageMetadata)
        {
            PageMetadata = pageMetadata;
            Page = ActiveStoryPageMetadata.LoadPage(pageMetadata);
            BoundingBox = new Rect(0,0,0,0);
            UiElements = new List<UIElement>();
        }
        public LinkMapPageElement(ActiveStoryPageMetadata pageMetadata, Rect boundingBox, IList<UIElement> elementList)
        {
            PageMetadata = pageMetadata;
            Page = ActiveStoryPageMetadata.LoadPage(pageMetadata);
            BoundingBox = boundingBox;
            UiElements = new List<UIElement>(elementList);
        }
    }
}
